﻿using UnityEngine;
using System.Collections;

public class MainMovePosition : MonoBehaviour
{

    public float MainBGspeed = 2f;
    void Start()
    {

    }


    void Update()
    {
        MainBGMove();
    }

    private void MainBGMove()
    {
        if (transform.position.x >= -15)
        {
            transform.Translate(Vector3.left * MainBGspeed * Time.deltaTime, Space.Self);
        }
    }
}
